<?php require 'lib/session_verify.php' ?>
<?php require 'lib/examed_verify.php' ?>
<?php
require 'lib/student_true_false_anwser.php';
session_start();
define('NUM_TF_ITEM', 20);
for($i = 1 ; $i < NUM_TF_ITEM + 1 ; ++$i) {
	$itemno = 'tfitem' . $i;
	$itemid = 'tfitem' . $i . 'id';
	$stfa = new StudentTFAnwser;
	$stfa->sid = $_SESSION['sid'];
	$stfa->tfitemid = $_POST["$itemid"];
	$stfa->stuselect = $_POST["$itemno"];
	$_SESSION["$itemno"] = $stfa; /* 此处或许传引用比较好 */
}

session_write_close();

header('Location: exam_subjective.php');
?>
